package com.atguigu.chapter02

object Test02 {
  //打印九层塔
  def main(args: Array[String]): Unit = {
    for(i<- 1 to 9 ){
      for (j<- 1 to (9-i)){
        print(" ")
      }
      for (k<- 1 to (2*i-1)){
        print("*")
      }
      println()
    }
  }

}
